package com.module.controller;

import com.module.framework.domain.ResponseResult;
import com.module.framework.service.DashboardService;
import com.module.framework.vo.DashboardVO;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RestController
@RequestMapping("/admin/dashboard")
public class DashboardController {

    @Resource
    private DashboardService dashboardService;

    @GetMapping("/info")
    public ResponseResult dashboardInfo() {
            DashboardVO dashboardVO = dashboardService.getData();
            return ResponseResult.okResult(dashboardVO);
    }

}
